package com.sgame.smobigame;

import java.util.ArrayList;

import android.app.Activity;
import android.graphics.BitmapFactory;
import android.os.Bundle;
import android.util.Log;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.ListView;
import android.widget.TextView;

public class ProfileView extends Activity  {
	ImageView ivAvatar;
	TextView tvStt, tvCoin;
	EditText etHappen;
	Button btPost;
	
	private ListView lvHappen;
	private ArrayList<itemHappening> array; // mang goc
	private HappeningAdapter adapter;
	private String[] arrayDate = { "11/11/2013", "11/11/2013" };
	private String[] arrayContent = { "Ha noi", "Hai Phong" };
	private int[] arrayPic = { R.drawable.ic_launcher, R.drawable.ic_launcher };

	protected void onCreate(Bundle savedInstanceState) {

		super.onCreate(savedInstanceState);
		setContentView(R.layout.sgame_profile);
//
//		ivAvatar = (ImageView) findViewById(R.id.ivAvatar);
//		tvStt = (TextView) findViewById(R.id.tvStatus);
//		tvCoin = (TextView) findViewById(R.id.tvCoins);
//		etHappen = (EditText) findViewById(R.id.etHappening);
//		btPost = (Button) findViewById(R.id.btPost);

		lvHappen = (ListView) findViewById(R.id.lvHappening);
		array = new ArrayList<itemHappening>();
		adapter = new HappeningAdapter(this, R.layout.sgame_happening_item,
				array);
		for (int i = 0; i < 2; i++) {
			itemHappening happen = new itemHappening(
					BitmapFactory.decodeResource(getResources(), arrayPic[i]),
					arrayDate[i], arrayContent[i],
					BitmapFactory.decodeResource(getResources(), arrayPic[i]));
			array.add(happen);
			Log.d("Ab","b");
		}
		
//lvHappen.setAdapter(adapter);
	Log.d("Ab","c");
	}
	

	

}
